package com.fengchao.api.dao.usr;

import com.fengchao.api.dao.BaseMapper;
import com.fengchao.model.usr.UsrThirdpartAccountInfo;
import org.apache.ibatis.annotations.Param;

public interface UsrThirdpartAccountInfoMapper extends BaseMapper<UsrThirdpartAccountInfo> {

    /**
     * 根据userId查询第三方账号
     *
     * @param userId
     * @return
     */
    UsrThirdpartAccountInfo findUsrThirdpartAccountInfoByUserId(Integer userId);

    /**
     * 根据类型查询openid
     *
     * @param openId
     * @param thirdAccountType
     * @return
     */
    UsrThirdpartAccountInfo findUsrThirdpartAccountInfoByOpenId(@Param("openId") String openId, @Param("thirdAccountType") String thirdAccountType);

}